package com.mobile.renter.services {
   import com.flex.util.proxy.BaseProxy;
   import com.mobile.renter.models.RealTimeOrder;
   
   public class OrderService extends BaseProxy {
      private static const SERVICE_NAME:String = "orderService";
      
      public function OrderService() {
         super(SERVICE_NAME);
      }
      
      public function createTaxiOrder(
         order:RealTimeOrder,
         callback:Function = null,
         context:Object = null):void {
         callService("createTaxiOrder", [order], callback, context);
      }
      
      public function findTaxiOrdersByUserId(
         userId:Number,
         callback:Function = null,
         context:Object = null):void {
         callService("findTaxiOrdersByUserId", [userId], callback, context);
      }
      
      public function confirmTaxiOrder(
         order:RealTimeOrder,
         callback:Function = null,
         context:Object = null):void {
         callService("confirmTaxiOrder", [order], callback, context);
      }
      
      public function cancelTaxiOrder(
         order:RealTimeOrder,
         callback:Function = null,
         context:Object = null):void {
         callService("cancelTaxiOrder", [order], callback, context);
      }
   }
}